package com.example.logactivity;

import android.content.Intent;
import android.support.v7.app.AppCompatActivity;
import android.os.Bundle;
import android.util.Log;
import android.view.View;
import android.widget.Button;

public class LogActivity extends AppCompatActivity {

    private Button myButton;
    static final String TAG = "LogActivity";
    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_log);
        Log.v(TAG, "FirstActivity ---> onCreate");
        myButton = (Button) findViewById(R.id.myButton);
        myButton.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View v) {
                Intent intent = new Intent(LogActivity.this, LogActivity2.class);
                startActivity(intent);
            }
        });
    }

    @Override
    protected void onDestroy() {
        Log.v(TAG, "FirstActivity ---> onDestroy");
        super.onDestroy();
    }

    @Override
    protected void onPause() {
        Log.v(TAG, "FirstActivity ---> onPause");
        super.onPause();
    }

    @Override
    protected void onRestart() {
        Log.v(TAG, "FirstActivity ---> onRestart");
        super.onRestart();
    }

    @Override
    protected void onResume() {
        Log.v(TAG, "FirstActivity ---> onResume");
        super.onResume();
    }

    @Override
    protected void onStart() {
        Log.v(TAG, "FirstActivity ---> onStart");
        super.onStart();
    }

    @Override
    protected void onStop() {
        Log.v(TAG, "FirstActivity ---> onStop");
        super.onStop();
    }
}
